package Oct_2020_BETA.part6;

public class Oct_Pra1 {
    public static void main(String[] args) {
        Thread t1=new MyTickets();
        Thread t2=new MyTickets();
        Thread t3=new MyTickets();
        Thread t4=new MyTickets();
        Thread t5=new MyTickets();
        Thread t7=new MyTickets();
        Thread t8=new MyTickets();
        Thread t9=new MyTickets();
        Thread t10=new MyTickets();
        t1.start();
        t2.start();
        t3.start();
        t4.start();
        t5.start();
        t7.start();
        t8.start();
        t9.start();
        t10.start();
    }
}
class MyTickets extends Thread{
    static int tickets=100;

    @Override
    public void run() {
        while (tickets>0){
            tickets--;
            System.out.println(this.getName()+"--"+tickets);
        }
    }
}